﻿using ImageMagick;
using System.Drawing;

namespace Common.Core.ImageHelper
{
    public static class ResizeImage
    {
        public static Image Fun1(Image sourceImage, int destWidth, int destHeight)
        {
            var destImage = new MagickImage(StreamByteImageConverter.ImageToBytes(sourceImage));

            destImage.Resize(destWidth, destHeight);

            return StreamByteImageConverter.BytesToImage(destImage.ToByteArray());
        }
    }
}
